package com.shop.zkmall.app.controller.a;

import cn.hutool.json.JSONUtil;
import com.shop.zkmall.app.common.RocketConstants;
import com.shop.zkmall.app.service.a.ICereBuyerSystemConfigService;
import com.shop.zkmall.app.utils.LoginHelper;
import com.shop.zkmall.commons.domain.buyer.CereBuyerUser;
import com.shop.zkmall.commons.domain.shop.CereShopComment;
import com.shop.zkmall.commons.result.R;
import io.swagger.v3.oas.annotations.Operation;
import io.swagger.v3.oas.annotations.tags.Tag;
import lombok.RequiredArgsConstructor;
import lombok.extern.slf4j.Slf4j;
import org.apache.rocketmq.spring.core.RocketMQTemplate;
import org.springframework.data.repository.query.Param;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import java.util.HashMap;
import java.util.Map;

@Slf4j
@RestController
@RequestMapping("policy")
@RequiredArgsConstructor
@Tag(name = "协议模块", description = "协议模块")
public class PolicyController {


    private final ICereBuyerSystemConfigService iCereBuyerSystemConfigService;

    /**
     * 协议政策
     * 1隐私协议 2用户政策
     */
    @PostMapping("/getPolicy")
    @Operation(summary = "协议政策")
    public R<?> getPolicy(@Param("type") Integer type) {
        return iCereBuyerSystemConfigService.getPolicy(type);
    }
}
